struct uku_version_check_args {
	union uk_header header;
	// IN/OUT
	u16 major;
	u16 minor;
	u8 padding[4];
};

struct kbase_uk_mem_alloc {
	union uk_header header;
	// IN
	u64 va_pages;
	u64 commit_pages;
	u64 extent;
	// IN/OUT
	u64 flags;
	// OUT
	u64 gpu_va;
	u16 va_alignment;
	u8 padding[6];
};

struct kbase_uk_mem_free {
	union uk_header header;
	// IN
	// dump gpu 1024
	u64 gpu_addr;
	// OUT
};

struct kbase_uk_mem_alias {
	union uk_header header;
	// IN/OUT
	u64 flags;
	// IN
	u64 stride;
	u64 nents;
	union kbase_pointer ai;
	// OUT
	u64 gpu_va;
	u64 va_pages;
};

struct kbase_uk_mem_import {
	union uk_header header;
	// IN
	union kbase_pointer phandle;
	u32 type;
	u32 padding;
	// IN/OUT
	u64 flags;
	// OUT
	u64 gpu_va;
	u64 va_pages;
};

struct kbase_uk_mem_flags_change {
	union uk_header header;
	// IN
	u64 gpu_va;
	u64 flags;
	u64 mask;
};

struct kbase_uk_job_submit {
	union uk_header header;
	// IN
	// trace cpu base_jd_atom_v2 nr_atoms
	union kbase_pointer addr;
	u32 nr_atoms;
	u32 stride;
	// OUT
};

struct kbase_uk_post_term {
	union uk_header header;
};

struct kbase_uk_sync_now {
	union uk_header header;

	// IN
	struct base_syncset sset;

	// OUT
};

struct kbase_uk_hwcnt_setup {
	union uk_header header;

	// IN
	u64 dump_buffer;
	u32 jm_bm;
	u32 shader_bm;
	u32 tiler_bm;
	u32 unused_1; 
	u32 mmu_l2_bm;
	u32 padding;
	// OUT
};

struct kbase_uk_hwcnt_reader_setup {
	union uk_header header;

	// IN
	u32 buffer_count;
	u32 jm_bm;
	u32 shader_bm;
	u32 tiler_bm;
	u32 mmu_l2_bm;

	// OUT
	s32 fd;
};

struct kbase_uk_hwcnt_dump {
	union uk_header header;
};

struct kbase_uk_hwcnt_clear {
	union uk_header header;
};

struct kbase_uk_fence_validate {
	union uk_header header;
	// IN
	s32 fd;
	u32 padding;
	// OUT
};

struct kbase_uk_stream_create {
	union uk_header header;
	// IN
	char name[32];
	// OUT
	s32 fd;
	u32 padding;
};

struct kbase_uk_gpuprops {
	union uk_header header;

	// IN
	struct mali_base_gpu_props props;
	// OUT
};

struct kbase_uk_mem_query {
	union uk_header header;
	// IN
	u64 gpu_addr;
	u64 query;
	// OUT
	u64 value;
};

struct kbase_uk_mem_commit {
	union uk_header header;
	// IN
	u64 gpu_addr;
	u64 pages;
	// OUT
	u32 result_subcode;
	u32 padding;
};

struct kbase_uk_find_cpu_offset {
	union uk_header header;
	// IN
	u64 gpu_addr;
	u64 cpu_addr;
	u64 size;
	// OUT
	u64 offset;
};

struct kbase_uk_get_ddk_version {
	union uk_header header;
	// OUT
	char version_buffer[version_string_size];
	u32 version_string_size;
	u32 padding;
};

struct kbase_uk_disjoint_query {
	union uk_header header;
	// OUT
	u32 counter;
	u32 padding;
};

struct kbase_uk_set_flags {
	union uk_header header;
	// IN
	u32 create_flags;
	u32 padding;
};

struct kbase_uk_ext_buff_kds_data {
	union uk_header header;
	union kbase_pointer external_resource;
	union kbase_pointer file_descriptor;
	u32 num_res;		
	u32 padding;
};

struct kbase_uk_keep_gpu_powered {
	union uk_header header;
	u32 enabled;
	u32 padding;
};

struct kbase_uk_context_id {
	union uk_header header;
	// OUT
	int id;
};

struct kbase_uk_tlstream_acquire {
	union uk_header header;
	// IN
	// OUT
	s32 fd;
};

struct kbase_uk_tlstream_flush {
	union uk_header header;
	// IN
	// OUT
};

struct kbase_uk_soft_event_update {
	union uk_header header;
	// IN
	u64 evt;
	u32 new_status;
	u32 flags;
};

struct kbase_uk_mem_jit_init {
	union uk_header header;
	// IN
	u64 va_pages;
};
